<?php 
/**
 * @version			$Id$
 * @author			Richard Asp
 * @package			Joomla
 * @subpackage		gnudoor
 * @copyright		(C) 2010 gnudoor LLC
 * @license      GNU/GPL, see LICENSE.php
 * Joomla! is free software. This version may have been modified pursuant
 * to the GNU General Public License, and as distributed it includes or
 * is derivative of works licensed under the GNU General Public License or
 * other free or open source software licenses.
 * See COPYRIGHT.php for copyright notices and details.
 */

defined( '_JEXEC' ) or die( 'Restriced access' ); 
$params = &JComponentHelper::getParams( 'com_gnudoor' );
$topalias = $params->get( 'Provider List page top' );
$bottomalias = $params->get( 'Provider List page bottom' );

$model =& $this->getModel('Providers');
$topID = $model->getArticleID($topalias);
$topid = $topID->id;
$bottomID = $model->getArticleID($bottomalias);
$bottomid = $bottomID->id;
JHTML::_('stylesheet', 'view.css', 'components/com_gnudoor/assets/css/');
JHTML::_('stylesheet', 'form.css','components/com_gnudoor/assets/css/');
JHTML::_('stylesheet', 'tabs.css','components/com_gnudoor/assets/css/');
?>
<?php echo file_get_contents($this->articlebase . $topid);?>
<ul id="globalnav">
  <li><a href="<?php echo $this->link1;?>" class="<?php echo $this->class1; ?>"><?php echo $this->text1; ?></a></li>
  <li><a href="<?php echo $this->link2;?>" class="<?php echo $this->class2; ?>"><?php echo $this->text2; ?></a></li>
</ul>

<div id="form_container" class="mylist">

<form id="adminForm" action="index.php" method="post" name="adminForm">
<div>&nbsp;</div>
<table id="box-table-a">
<col width="80px" />
<col width="200px"  />
<col width="80px"  />
<col span="2" width="150px"  />
  <tr>
    <th scope="col"><?php echo $this->titles[formDate];?></th>
    <th scope="col"><?php echo $this->titles[formName];?></th>
    <th scope="col"><?php echo $this->titles[formDueDate];?></th>
    <th scope="col"><?php echo $this->titles[formDescription];?></th>
    <th scope="col"><?php echo $this->titles[formUser];?></th>
    <th scope="col">Actions</th>
  </tr>
<?php
if( count( $this->rows )) :
	foreach($this->rows as $row) {
?>
   <tr>
    <td><?php echo $row->dateAdded; ?></td>
    <td><a href="<?php echo $thisview; ?>" title="<?php echo $row->description; ?> "><?php echo $row->name; ?></a></td>
    <td><?php echo $row->dateDue; ?></td>
    <td><?php echo $row->description; ?></td>
    <td><?php echo $row->userid; ?></td>
    <td nowrap="nowrap"><?php echo $row->tolink; ?></td>
  </tr>
<?php } endif; ?>
</table>
</form>
</div>

<?php echo file_get_contents($this->articlebase . $bottomid);?>